package server;

import sluentities.ClassifierResult;

import java.util.List;

/**
 * Created by sunjia on 2018/2/28.
 */
public class testMaxEnt {

    private MaxEntClassifier classifier;

    public testMaxEnt() throws Exception {
        classifier = new MaxEntClassifier();
    }


    public static void main(String[] args) throws Exception {

        String line = "五十八的飞享套餐";
        testMaxEnt test = new testMaxEnt();
        List<ClassifierResult> classifierResults = test.classifier.predict(line);//获取分类器结果
        if (classifierResults.size()>0) {
            for (ClassifierResult c : classifierResults) {
                System.out.println(c.getAnswer()+c.getScore());
            }
        }
    }
}
